package com.lzq.springioc;

import com.lzq.springioc.beanconfig.User;
import com.lzq.springioc.component.UserComponent;
import com.lzq.springioc.configuration.UserConfiguration;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ApplicationContext;

@SpringBootApplication
public class SpringIocApplication {
	public static void main(String[] args) {
		ApplicationContext context = SpringApplication.run(SpringIocApplication.class, args);
		User user1 = (User)context.getBean("u1");
		System.out.println(user1);
	}
}
